---
layout: page
---
{{page.description | markdownify}}
{% if page.descriptionDetails %}
   {{page.descriptionDetails | markdownify}}
{% endif %}

{% if page.rationale %}
   <h5>Rationale</h5>
   {{page.rationale | markdownify}}
{% endif %}

{% if page.typescriptOnly or page.hasFix or page.requiresTypeInfo %}
   <h5>Notes: </h5>
    <div class="rule-features">
        {% if page.typescriptOnly %}
            <span class="feature feature-ts-only" title="This rule cannot be run against JavaScript files">TS Only</span>
        {% endif %}
        {% if page.hasFix %}
            <span class="feature feature-fixer" title="This rule has the ability to auto-fix violations">Has Fixer</span>
        {% endif %}
        {% if page.requiresTypeInfo %}
            <a class="feature feature-requires-type-info" href="/tslint/usage/type-checking" title="This rule requires type information to run. Click to learn more.">Requires Type Info</a>
        {% endif %}
    </div>
{% endif %}

<h3>Config</h3>
{{page.optionsDescription | markdownify}}

<h5>Config examples</h5>
{% for example in page.optionExamples %}
<pre>
"{{page.ruleName}}": {{example}}
</pre>
{% endfor %}

<h5>Schema</h5>
<pre>
{{page.optionsJSON}}
</pre>

{% if page.codeExamples %}
    <h3>Code examples: </h3>
    {% for codeExample in page.codeExamples %}
    <div class="wrapper__code-example">
        <h5>{{ codeExample.description }}</h5>
        {{ codeExample.config | markdownify }}
        <h6 class="feature">Passes</h6>
        <div class="code-example">
            {{ codeExample.pass | markdownify }}
        </div>
        {% if codeExample.fail %}
        <h6 class="heading-fail">Fails</h6>
        <div class="code-example code-example-fail">
            {{ codeExample.fail | markdownify }}
        </div>
        {% endif %}
    </div>
    {% endfor %}
{% endif %}
